<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .p1{
            width: 500px;
            height: 500px;
            /* background-color: aquamarine; */
            margin: auto;
            margin-top: 10px;
        }
        .p2{
            background-color: cadetblue;
            width: 320px;
            height: 46px;
            margin-top: 57px;
            margin-left: -1px;
        }
        .p3{
              width: 200px;
              height: 34px;
                margin-left: 140px;
                margin-top: 68px;
        }
        .p4{
              width: 200px;
              height: 34px;
                margin-left: 140px;
                margin-top: 23px;
        }
        .p5{
            /* margin: auto; */
            /* margin-left: 205px; */
           position: relative;
           top: 67px;
           left: 170px;
        }
        .p6{
       position: relative;
           top: 67px;
           left:104px;
        }
        .p10{
            position: relative;
            top: -48px;
            left: 173px;
        }
        .p11{
             position: relative;
            top: -48px;
            left: 200px;
        }
</style>
</head>
<body>

 <div class="p1">
        <div>
           <h2 class="p5">你以注册成功</h2>
           <h3 class="p6">用户你好请使用
          <a href="">QQ邮箱</a>
           进行登录
           </h3>
        </div>
        <input id="username" name="username" tabindex="1" accesskey="n" type="text" value="" size="25" placeholder="手机号/邮箱" class="p3"><br> 
        <input id="password" name="password"  tabindex="2" accesskey="p" type="password" value="" size="25" placeholder="密码" class="p4"><br>
        <input type="checkbox" class="p10"><span class="p11">记住密码</span>
        <button onclick="dl()" class="p2">登录</button>
    </div>
    
    <script>
                var i=localStorage.getItem('is')
                i=false
                if(i){
                    location.assign('./6.3.项目首页.html')
                }       
                var inp1=document.querySelectorAll('input')[0]
                var inp2=document.querySelectorAll('input')[1]
          function dl(){
              var a=localStorage.getItem('name')
              var b=localStorage.getItem('password')
              if(inp1.value==a && inp2.value==b){
                var is=document.querySelectorAll('input')[2]
                if(is.checked){
                localStorage.setItem('is',false)
                  location.assign('./6.3.项目.html')  
                }
                 console.log(is);
            }else{
                localStorage.removeItem('is')
                alert('密码错误')
            }
           
          }
          
          
          
    </script>
</body>
</html>